-
Notifications
You must be signed in to change notification settings - Fork 146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add support for breadcrumbs
param in front matter for showing/hiding breadcrumbs on specific pages
#367
Conversation
✅ Deploy Preview for hugo-hextra ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @ggwicz, thank you for the PR. I was also thinking about adding this recently.
I wonder if changing the flag name from hideBreadcrumbs
to simply:
---
breadcrumbs: true # or false
---
would make more sense, similar to the toc
flag.
Yeah good call @imfing! Fixed! |
hideBreadcrumbs
functionality for hiding breadcrumbs atop specific pagesbreadcrumbs
param in front matter for showing/hiding breadcrumbs on specific pages
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work, appreciate for adding the doc @ggwicz
* refactor: extract card shortcode to partial (imfing#339) * refactor: extract card shortcode to partial * chore: update hugo stats * feat: configurable cols for feature-grid shortcode (imfing#342) * feat: configurable cols for feature-grid shortcode * chore: update css files * chore: add hextra prefix to cards css var * chore: rebuild css * chore: add quicklink script to head in doc site * docs: add more projects to showcase * feat: add styles for definition list (imfing#344) * feat: dd styles for definition list * chore: re-generate css * feat: pdf shortcode (unstable) (imfing#345) * chore: improve search bar shortcut display (imfing#346) * chore: improve search bar shortcut display * chore: remove focusout handler * feat: support sort blog post list page (imfing#348) * chore: bump hugo version to 0.124.1 in devcontainer * chore: add homebrew to devcontainer [skip ci] * chore: revert adding homebrew to devcontainer * bloat up the image size and increase the cold start time [skip ci] * docs(i18n): add zh-cn translation of RSS button (imfing#353) I notice that RSS button is missed when switching language to Chinese in the documentation of Hextra. It's added now in this PR, hope it helps. * fix: js scripts not in body element (imfing#356) * chore(deps): bump npm package versions (imfing#361) * chore(deps): bump npm package versions * recompile css * chore: recompile css * chore: 2023 -> 2024 * chore(deps): add taskfile and bump assets lib versions (imfing#362) * chore: add Taskfile for automating common tasks * chore(deps): bump versions of third-party libraries in assets * katex 0.16.8 -> 0.16.10 * mermaid -> 10.9.0 * ci: use actions/configure-pages and bump hugo version * docs: update zh-cn translation (imfing#365) * docs: fix deploy-site zh-cn lang filename * docs: update zh-cn sidebar titles * docs: fix deploy site title * docs: fix deploy-site zh-cn lang filename (imfing#371) * chore: add i18n links in README (imfing#374) * docs: add i18n README links * Update README.md * Update README.fa.md * Update README.zh-cn.md --------- Co-authored-by: Xin <xin@imfing.com> * docs: add showcase - HITSZ OpenAuto (imfing#373) * docs: add showcase - HITSZ OpenAuto * alter showcase image * Update index.md * Update index.zh-cn.md --------- Co-authored-by: Xin <xin@imfing.com> * i18n: add Dutch translation (imfing#383) Added Dutch translation. * docs(fix): correct a mistake in markdown guide (imfing#394) Fix code mistake by making sure backticks are inserted at start and end of example text * feat: add hextra hero-container shortcode (imfing#389) * Implement hextra hero-container * Fix width * Fix width * Fix width * Set number of columns * Fix display for mobile devices * Trim image prefix * Implement image card * Fix width * Fix css * chore(showcase): add AXIVO docs (imfing#400) * chore: update AXIVO docs image format (imfing#402) * fix: use `hugo.IsMultilingual` to replace deprecated `.Site.IsMultiLingual` (imfing#404) * i18n: add Ukrainian translation (imfing#403) * i18n: add Hebrew translation (imfing#405) * feat: add support for `breadcrumbs` param in front matter for showing/hiding breadcrumbs on specific pages (imfing#367) * feat: add support for `hideBreadcrumbs` front-matter param * docs(en): add some docs about breadcrumb nav, including new hideBreadcrumbs param * fix: fix typo in hideBreadcrumbs param check in breadcrumbs.html partial * docs(en): tidy up the Breadcrumb Navigation documentation * fix: rework hideBreadcrumbs param to breadcrumbs; update docs accordingly * fix: use relpermalink in breadcrumb --------- Co-authored-by: Xin <xin@imfing.com> * feat: add customize flexsearch tokenize feature instruction to docs (imfing#322) * feat: add customize flexsearch tokenize feature instruction to docs * Update configuration.md * Update configuration.md * Update configuration.zh-cn.md --------- Co-authored-by: loenvom <loenvom@qq.com> Co-authored-by: Xin <xin@imfing.com> * docs: list code block copy button config (imfing#412) * fix: list code block copy button config * Mention copy button config in the guide * fix: properly handle tabs overflow (imfing#422) * fix: properly handle tabs overflow * chore: rebuild css * docs: fix typo in chinese doc (imfing#430) * docs: add missing Markdown syntax examples (imfing#415) * chore: bump npm package versions * chore: bump hugo versions * feat: add tag support for card shortcode (imfing#427) * styles: accept tags on cards with default and custom colors * styles: compile css * chore: improve tags styling on card (imfing#431) * chore: improve tags styling on card * chore: npm run build:css * fix: add integrity sha384 to js script on example site --------- Co-authored-by: Xin <xin@imfing.com> Co-authored-by: Xin <fuxin1997@gmail.com> Co-authored-by: Kowyo <kowyo@outlook.com> Co-authored-by: Robb Shecter <robb@public.law> Co-authored-by: 纳兰音韵 <91950505+naranyinyun@users.noreply.github.com> Co-authored-by: Kowyo <110339237+kowyo@users.noreply.github.com> Co-authored-by: longlin li <gnulonglin@gmail.com> Co-authored-by: Maxwell Jay <MaxwellJay@jaylab256.onmicrosoft.com> Co-authored-by: Sebastian Broekhoven <2205121+sbroekhoven@users.noreply.github.com> Co-authored-by: Lucas <100660343+lulunac27a@users.noreply.github.com> Co-authored-by: Floren Munteanu <fmunteanu@users.noreply.github.com> Co-authored-by: Andreas Deininger <andreas@deininger.net> Co-authored-by: Serhii Pryimachuk <serg@pryimach.uk> Co-authored-by: Shahar Naveh <50263213+ShaharNaveh@users.noreply.github.com> Co-authored-by: George Gecewicz <875201+ggwicz@users.noreply.github.com> Co-authored-by: loenvom <59039948+loenvom@users.noreply.github.com> Co-authored-by: loenvom <loenvom@qq.com> Co-authored-by: yuri <1969yuri1969@gmail.com> Co-authored-by: jinzhongjia <mail@nvimer.org> Co-authored-by: Julia March <101819212+juliamrch@users.noreply.github.com> Co-authored-by: Jason Thrsher <jthrasher@zagtech.com>
Hi there! Hextra is awesome and I wanted to propose a feature that I've found useful recently: the ability to hide breadcrumbs on specific pages.
This has been especially useful on "index" pages, for example, where even with a custom
linkTitle
there's just not much value added from the breadcrumb.I've also included some documentation updates for breadcrumbs in general—and for this
hideBreadcrumbs
option specifically—as I wasn't finding that information elsewhere.Example
Before
/docs
/docs/processes/story-points
/docs
), the titleDocumentation
being repeated twice by the auto-generated breadcrumbs isn't really helpful./docs/processes/story-points
in this example:After
With this new
hideBreadcrumbs
param, you can have the best of both worlds.I add it to the front matter of
/content/docs/_index.md
:And then no longer have it on the
/docs
page, but all the other breadcrumbs generation continues to work exactly the same./docs
/docs/processes/story-points